Ok here is my question. I have two column that I am trying to merge. The first column I have set to be two digits. The second column is set to be three digits. The problem is if the first digit in the second column is a 0 it gets dropped once the two columns are merged. How do I stop this from happening. I need the merged columns to be 5 digits.
When i use docmd.sendoject and try to attach my report in rtf it's dropping my checkboxes. I need the checkboxes...does anyone know how to solve this problem.
I am importing a table from a Clarion TPS database which stores several types of data in a "IDVAL" field. The field next to it, "LBLNUM" defines what the data type is. This creates a problem, as IDVAL is a text field, which means all data stored in it (no matter what the type) is then stored as text. This includes date fields. Since they are stored as text, they end up as 5 digit serial dates, similar to how excel handles dates (with each day after 1/1/1900 being +1).
So I have a union query which derives all the values stored in IDVAL for each unique record. My query which creates my export combines this data with several calculated fields to create my final export.
Everything looks great on this final export except for my date fields, which are all 5 digit numbers (like 77945).
I have been searching for a date function that will format this back to a standard date, however I have yet to find anything that works. Is there no way to format a 5 digit serial date back to a standard date within access by using a function? Every answer I find says to redefine the table to a date field, however I don't have this option since the field in question stores a lot more than just dates.
I can't display a 17 digit number in my table without losing the last couple of digits to 'rounding'. I've tried 'doubling' the field size but to no avail....whatever I attempt loses the last couple of digits to a 'nice round figure'.....
The numbers had initially been imported as text...which is really what they ought to be as they're identification numbers, but I had some issues using the find 'duplicate values' query and conjectured that was because the ID numbers had been defined as text---->though I could be wrong.
The VAL function works (to convert the text to numbers) but again -- I lose the detail of the last couple of digits.
I've been beating my head against this wall the entire day and at the very least, would like to know if what I'm attempting is viable. I've stumbled through function queries (with some success) and react like a deer in the headlights when it comes to VBA....
I am calculating the check digit for a 13 digit number in Excel and I need to be able to do it in Access.
My Excel formula; =1&E1&MOD(-SUM(MID(1&E1&0,{1,3,5,7,9,11,13;2,4,6,8,10,12,14}, 1)*{3;1}),10) -- cell E1 holds the base 12 digit number. My attempt to convert to Access; =1 & [txtBase] & [-SUM(MID("1" & [txtBase] &0,{1,3,5,7,9,11,13;2,4,6,8,10,12,14},1)*{3;1}) mod 10] -- txtBase holds the base 12 digit number
I had a database that wasn't normalised but after some (a lot of) help here it now is. I have quite a few records that need to come accross to the new database and I was wondering:
I can drop the NAME/JOB_TITLE/BASE information in OK but can I place the trainig done for each staff member in? I was thinking that if I dropped the details in the TRAINING_DONE table and manually entered the STAFF_NO which is the primary key, would that work?
i'm trying to drop importerror tables with code, but this isn't working
i am not sure if its to do with unusual characters in the import errors tables ( error tables generated by access when importing spreadsheets etc
any ideas why the code fails
error 3295 - syntax error
'drop errors tables first tdfdrop = 0 For Each tdf In CurrentDb.TableDefs If InStr(1, tdf.Name, "ImportErrors") > 0 Then tdfdrop = tdfdrop + 1 sqlstrg = "drop table " & tdf.Name DoCmd.RunSQL sqlstrg End If Next tdf If tdfdrop > 1 Then Call MsgBox("Dropped: " & tdfdrop & " importerror tables")
I working on a Project in which I have a table that is being updated from the values in another table. The problem that the table is deleted and rebuilt in code before the Query is executed. Access is so smart, it drops the links between the tables when the table is deleted even if the query isn't open.
To get around this, I recreate the SQL in Code for the Named Query involved just before I execute it. This works OK but probably creates bloat and is a little slower.
Is there a better way around this problem other than recreating the SQL for the Update Query each time?
I'm able to pull users that are logged into our network but our company uses a name that has their employee number as well. So deponding on when they were hired it could be a 5 or 6 digit number. so an example would be JSmith123456 or it could be JSmith12345 so is there a way to drop the numbers at the end? Meaning if they are entering data into a form that pulls their name can I drop off those last digits in the name field?
I have a number of linked tables that vary depending on use. How to delete them or drop them all from the database? I produced/stole some code that deleted all tables - but it didn't delete the linked ones.
I am having an issue with an Access import. It worked correctly bringing in a sharepoint spreadsheet until a date field was added to the spreadsheet and the structure to the database. Now it drops any additional fields that are added. At first I thought if I added a filler field after the field I needed that it would still drop the last field but it dropped them both. If I insert the field in the middle of the spreadsheet....(where I really want it). It drops the last field of the email address. Which I need to send out notifications. I have tried designing a complete new table and importing it, but it continues to do the same thing.
Not sure if my problem is with the spreadsheet or Access. Somehow it is still looking at the old structure when I import even if I create a new table. Not sure what is happening.
I have created some queries that are joined on long text fields (80-120 characters). I can save the query in the graphic query design window. But when I reopen the window I get messages that the Joins have been deleted. I cannot find any references to this issue. Does anyone have experience or info on this?
I don't need a lecture about the use of long text fields in Query Joins. And yes I have used Search first.
I'm trying to create a report that pulls from two tables [tblTelephony] and [tblSales]. All data in my query is limited to a date range entered through a form.
For every record in [tblSales] (showing the agent made a sale) there is a record in [tblTelephony] (showing all the stats for the agent's day worked). [tblTelephony] has one date for each record. [tblSales] has two dates for each record. The sales dates are the date the services were ordered (matches the date worked in [tblTelephony]) and the date the services were installed.
In order to get an agent's MTD Sales stats I have to query the date range on Install dates. MTD Telephony stats are run on the same date range on telephony date. Where I run into an issue is with the sales that are ordered before the date range in question and installed during it.
I've run a separate query to sum the sales installed during the date range and used that sales value in my Telephony query. In order to get my data to show as accurately as possible, I had to create a relationship between the Order Date and the Telephony date. I'm really hoping to find a way to force the sum of sales in sales query to show in the sales column in the telephony query, regardless of the telephony date range and without adding telephony data for dates outside the range.
Example: Date Range = 2/1/14 - 2/24/14 Telephony Date = 2/3/14 Order Date = 2/3/14 Install Date = 2/14/14 Appears on report
Date Range = 2/1/14 - 2/24/14 Telephony Date = 1/31/14 Order Date = 1/31/14 Install Date = 2/3/14 Does not appear on report
How to get the sale example on the bottom to show without removing the relationship?
Do this for A,B,and C and send the individual report in via email to them. To me it looks like a mail merge, but I don't know how to manipulate the data and put it into the layout. My real data has a lot of data, about 100 person, and about 60 product that falls into two categories. Is there anyway easy and fast way to do this? Please help! Thank you very much!
I am using a query for a word mail merge and would like to maintain the formating from Access into Word. Is this possible and if so how. If not, anyone have a clue how to do it in Word... I am importing the date and would like it to be long version (Friday, November 19, 2004) and it's giving me the short version (11/19/04),
I need some to PLEASE point me in the right direction.
I have a database of magazine articles that are listed like this:
Magazine Date Article Time 2003-01 Iran War Time 2003-01 Pres Campaign Time 2003-01 Polution Time 2003-02 Senate Race Time 2003-02 New Cars Time 2003-02 Cold Wave Hits
I need to merge that down to look like this:
Time 2003-01 Iran War,Pres Campaign,Polution Time 2003-02 Senate Race,New Cars,Cold Wave Hits
I am wanting to create letters in word to go out to trainees which lists the courses they are booked on. I have successfully created a query which has a parameter under the 'Trainee ID' field, where I put in the trainee ID number and the query pulls out the courses that particular trainee is on. However, when I try to mail merge this into word, it works well BUT...insists on creating a new document/letter for each course the person is booked on.
What I wanted was for it to list the courses below the trainee name but can't for the life of me get it to do this
Anyone got any ideas ? I would appreciate any help with this
I am trying to merge data with MS Word, but am getting problems. I only seem to be able to merge a single record. Can anyone help pls as this is quite urgent
I have created a mail merge from a query in Access and it works fine if you run it from word but I would like to know how to automate the mail merge from Access using the Command button. Please can someone advise.
I want to use an Access Table for a mail merge but when i try to use the merge option I get a pop up asking for a password. I put in my administrator password for the database and it tells me I dont have acess to the database. It has something to do with the passwords i put on the database.
Anyone have any ideas to what I need to do to get this to work?
Currently there is a MS Word application that runs a MS Access query to generate data for the Mail Merge with a document.
Does anyone have a suggestion as to how this process can be optimized? Specifically, looking to reduce the amount of time required to produce letters (best practices).
Hello- I am building an access database for a non- profit that does alot of mailings. My question is how to handle the people that live in the same house- ie: John and Mary Smith? Both have their own entry in the database, but I want to be able to send them one mailing to John and Mary Smith, rather than two addressed to each individually. Addressing the mailings to "Residents of", or something similar is to impersonal as many of them are donors. Any good ideas how to handle this? Thanks for any help!
I have numerous word docs that I need to mail too. What I am tring to acheive is how to link an active record that has been entered on a input form by the user to the various word docs as corressponding letters. This is how the user currently chooses which letter to use However, they are obviously entering the data manually as there is no merge facility.
The merge data is stored in a query called "QryMerge" is there any VB code that I could add to this
Private Sub cboReport_Change() On Error GoTo Err_Handler Dim stDocName As String
If [cboReport] = "L1" Then Dim taskid As Long Dim str As String str = "winword.exe " & "D:DataFrm_L1.doc" taskid = Shell(str, vbMaximizedFocus)
I'm using a query that selects all customers from a Customer table who haven't made any payments for a particular week and then sends a letter to them. I would like to use a command button on a form which the user can press and then view the letters for all the customers- they would only have to specify the week. Is this possible? Thanks
Am using below code for generating set of pdf files in a desired folder..similarly I have another code, which generates another set of pdf file in another folder.. Count and Filename is identical in both the folders and I need to merge the file names with identical names together....separate binder file would also work..
Private Sub Command14_Click() Dim strDefaultPrinter As String strDefaultPrinter = Application.Printer.DeviceName Set Application.Printer = Application.Printers("Adobe PDF")