With microsofts article, I have made to store multi options value of a list box in a text box with comma. However, since these are IDs being stored, I want these values to run a query and get results also.
But I am confused since have never used comma like in query
I used the get external data tab and went thru the process. everything looked good in the preview but when I clicked finish I got type mismatch errors and the data that was supposed to be in field 1 was in fieild 2 and so on.
I have inherited a database where technicians track equipment that has been repaired.In this database, there is a memo field where the technician lists all the part numbers he / she uses to repair the piece of equipment. This field was never reported against and was strictly used for reference. However, someone is coming to me now and asking that a report be generated with that information. Then she will separate those parts out on her end. because it is a free form field, the technician is not forced to put a comma between each part number. I was wondering if there is a way for the database to go through approximately 62,000 records and ensure that there is a comma between each part number? I was also wondering if there is way to program the database to automatically insert a comma after each part number.
I'm a new Access user. I'm looking for an easiest solution to combine more records into one, using comma delimited. Let's say that I have a table T1 with two columns Code and Client like this:
Code Client X C1 X C2 Y C1 Y C3 Z C1 Z C2 Z C4 Z C5
I need to see those records in a Query, grouped by "Code" with the Client's value combined like this:
I have a table (let's call it "tableA) with about 7 fields. One of the fields contains information that I need to do a query on so that I may find specific payees, for example:
The field is called "Payee" and in that field for each record, the information could be "At&T", "A T and T" or "Abercrombie & Fi", but there is also other information in that field along with At&T, etc., so the field for a record may look like this: A T AND T MOBILI A T AND T MOBILI 10 90034 Bill Pay or ABERCROMBIE & FI 3042 PP 10 9111 DIRECT
Is there a way to set up another table (let's call it tableB) to have all the Payees names (such as AT&T or whatever) in it and by the push of a button (maybe macro), have a query go out and find all matches from tableB in tablea?
So, basically have the query look in tableA and find all the matches from TableB. Please understand that tableA could have records that contain the same name, but spelled a number of different ways, for example, AT&T or A T and T or ATandT or ATT. Again these names may or may not be embedded in with other information in a field.
Or is there a way that an Access query can look into an external list and find the records, example:
Have a text (file) list with all the names (separated by a comma or space - AT&T, AT & T, Amercrombie and FI, Abercom&Fitch, etc. Now have a query go to that list and find all records that match in my tableA?
I have one Access Database and i want to import the flat file coming from Cisco Phone Logs, its a comma delimited that contains the column names in the first row, and in the second row, its the data type, then the succeeding rows contains the data of the logs which are in Comma separated values, I want to put it to my created table programmatically,I used Docmd.TransferText but this will not let me define the row which i wanted to start at row 3.
I created a form letter as an Access 2007 report. I want the greeting to read, "Dear [first_name]," e.g., "Dear Alan,". The [first_name] field is bound to said field in a query. When I just use the [first_name] field, I get "Dear Alan" with no comma. I've tried to add the comma various ways:
I'm trying to turn any period entered into a certain textfield on my form into a comma (to prevent access from turning 1.1 into 11 for example).
I have the on dirty event set to me.fieldname = replace(me.fieldname,".",",").
Everything works fine as long as I use the period key on the numpad. However, when I use the regular period key on the keyboard, it does not convert it.
I have developed a database but have had difficulty with sorting data within subform of a main form. The subform displays the related tasks that correspond with main form that has been selected. Within the main form I have also created a text field that defines a particular sorting sequence of the tasks found within the subform which is titled Task Sequence. What I would like to do, is use the Task Sequence field to sort the order of tasks within subform. I have tried: IIf([ID] Is Null, 0, Val([Task Sequence])) within the Advanced filter/sort but either it shows only the first task defined in the Task Sequence or it wants to filter the main form and not the subform.
Hi all, this is my first post, I'll try and make it a good one :-)
System: Windows 2000 Office 2000
I have a small network of PC's here which have access to our central database. I have a simple form created using the label wizard which is used to print address labels for mailing lists. On most of the PC's here it works fine but on one or two (which have no obvious difference in thier setup) I get an "ODBC--Call Failed" error and it won't run the report???? I have puzzled over this for a while when I decided that I would remove the Trim function from the lines of the address fields on the label, these are put in automatically by the label wizard. This stopped the error message and the reports now run. I don't know why this is happening but I am hoping someone will.
I have a table by name "newtab" and I was trying to import a tab delimited text file "newdata.txt" into newtab. The first line in the text file are the column names: SSN, Lastname, FirstName (all tab delimited though). The same field names exist in the destination file. However I am getting the error which says the "the field name SSN Lastname FirstName does not exist in the destination file" What could possibly be the problem? Since the field names are not separated in the error message, could it be that it is seeing all 3 field names as one and therefore cannot match them to the destination fields? Does that mean TAB cannot be used as the delimiter? Using the interactive IMPORT from access directly for the same files work really good though. However, I would like to do this programmatically since the files would be coming in weekly for me to load and they are many such files. The command I used is as below. Please I need help.
Think there are 50 comma separations all together. Anyway when I go to import / link my csv into access the data that is on the first row should it create individual fields where a comma has been placed... But it has doesnt quite worked, some of the fields are created and the rest have been put on a separate row! Rather than going to a new field. Rather having 50 fields I've got 21 fields and 3 rows or delimited text...
I have a text box that has an iif statement in it and a referenct to a numerical value that is suppose to be a currency.
The table that is providing the source for the report show the value as $x,xxx.xx and if a create a text box with just it in the report it shows as $x,xxx.xx but when I put it into the iif statement it shows as $xxxx.xx with no comma.
iif statement example in txtbox:
Code: =iif([Happy]=true,"I am happy with " & [value] & " in profits","I am sad with " & [value] & " in profits") [value] is suppose to be like $1,111.11 but instead their is no comma showing $1111.11.
I had to delete a database so I exported selected records using export as a text file thinking I would get some sort of delimited text file that I could later use. Instead I got some sort of fixed length file with .............. between records and | between fields.
I'd like to convert this data to a tab delimited file.
I am able to successfully export data from an Access 2010 Query to a Tab Delimited Text file without difficulty.My problem is that the Query includes several 'tick boxes'. The resulting text file shows the text boxes as 1 or 0 as appropriate. What I actually require is a Y/N result.To achieve the required Y/N result requires some fiddly find and replace editing which is complicated by the fact that the query also contains telephone numbers incorporating 1 & 0, This then requires further editing of individual records to convert misplaced Y/N back to 1/0. Is their any way that one can force the export to convert text boxes to Y/N rather than 1/0.
I need to create a command button to import a tab delimited text file into a table in Microsoft Access using VBA Code.
I have set up the button however I am unsure as to how I should approach it and what code i need. If anybody has any suggestions I would be very grateful.
I'm trying to import a pipe delimited text file into a table. I can import the entire table using the following code, but I only get one column of data (the entire data set in one column). If possible I would like to import with the columns defined or if not possible use some code for a function similar to text to columns.
A little background. I need to export the results of a query I use to build a report. For Print Master software I need the "Field Names" in the text file as well as the data for a Mail Merge in Print Master (PM).
"The field name information in the file you have specified is missing or not correctly formatted. The first line of the file must contain the database field names. Make sure the "Export Field Names" (or similar) option is selected in the program from which you are exporting data."
Trouble is, when trying to export the report or query, Access has no "Export Field Names" option. It works if I first export to Excel and then from Excel to "txt" then to Printmaster. I would like to eliminate the Excel step. Therefore, how do or can I get Access Export to transfer the "Field Names" along with the field data?
I have a single 'text' box on a form that captures test scores. The person inputting the test scores puts in all of the scores separated by commas (77, 85, 100, 75.5).. Up to 6 test scores can be placed in this single text box. The field is formatted for text. What I propose to do is take the numbers in the text box and average them out and then display the test scores average in a number field named 'avescores' next to this field in the form. Once the inputer puts the series of scores into the text box, they would hit an 'update' button next to this box to 'update' the 'avescores' box. Right now they use a number pad and add up the numbers manually then place the average into the avescores box....
What I'm stuck on is the filepath. The file path changes everytime. So I would like to have either the open dialog box (I've tried many different versions that I found on the web.) or to search by the account name for the folder and place the text file in there.
Here is one that is closely working how I want it to:
This is a function that I found, that opens a dialog box for the user to select the folder location. It works, but I can't seem to get it to work properly.
It prompts, the location, then once you select it and press ok. It will add the folder name to the full file name, and place the file in the default root path. Not the selected folder path.
So in the end it will look like this:
D:1_MainMyFolderName_MyTextFileName.txt
I'm somehow stuck on getting to seperate the file path from the file name, so you it look like this:
D:1_MainMyFolderNameMyTextFileName.txt
Code:
Dim MSg As String Dim SelectedDir As String Dim SelectedDirFinal As String Dim SelectedDirName As String Dim StrFolder As String
[Code] ....
I think it should be something very easy, that I just need a pair of fresh eyes to look.
I've tried the Fileobject, FileFolder method, but can't get the quite work properly.
I'm trying to import a text file with 273 fields into two tables. I've been able to do this with the code I found on an old thread and I'm now trying to accomplish everything with one step. The file I'm importing is tab delimited text file. With this current code I'm only able to populate the first record in the table and then I get error message. (Run-time error '3265') (Item cannot be found in the collection corresponding to the reqested name or ordinal).
Code:
Public Sub ImportTextFile() ' to use the ADODB.Recordset, be sure you have a reference set to ADO Dim rst As ADODb.Recordset Dim rst2 As ADODb.Recordset Dim strFile As String Dim strInput As String Dim varSplit As Variant Dim intCount As Integer
I'm having trouble converting text to proper text in Access 2010 using Windows 8.1 as OS.
The message I keep getting is:
The expression you entered contains invalid syntax. You omitted an operand or operator, you entered an invalid character or comma, or you entered text without surrounding it in quotation marks.