SELECT Institutions.*, Institutions.merge, Institutions.Inst_type
FROM Institutions
WHERE (((Institutions.merge)=True) AND ((Institutions.Inst_type)=[forms]![merge_inst_type]![Inst_type]));
and I had a command button which process
MergeAllWord ("select * from merge_query_true")
but I am getting an error like this "make sure the sql is correct , sql was
select * from merge_query_true
select * from merge_query_true ---- is this code ok?
If I had cut the part "AND ((Institutions.Inst_type)=[forms]![merge_inst_type]![Inst_type])); from the sql it works fine....
I was looking for some help. I am trying to setup a table with a field for web address. People are entering www.website.com etc however I need them to make sure it starts with http:// Is their any way I can put validation on the field to make sure that this is entered? Or maybe I could use an input mask?
The following SQL query is returning no records when I know for a fact there are some there! Can anyone please hlp me?!
Dim strSQL As String strSQL = "SELECT * FROM tblHirer WHERE HirerSurname= 'Forms!frmFinanceProposal!Child845!Text430'" rsFindDuplicates.Open strSQL, CurrentProject.Connection, adOpenKeyset, adLockOptimistic rsFindDuplicates.RecordCount
Also, I was wondering how I would put as 2nd filter on the recordset to equal a particular date?
I have a fax number field iwhich has a mask. +(000)-00-000-000 in a table of many records. The problem is that every record has a number in the first part of country code +(001)which must have come there by mistakes, few records have complete and true fax numbers.
I need a query that can Update this Fax_Number field where the length of the string is less than 7 digits. Some thing like UPDATE Contacts SET Contacts.Fax_Number = "" WHERE ((Len("Fax_Number")>"6"));
The first section is the Category, the second is the Product, the third is the SubProduct and the fourth is the keyword.
What is the best way to split each of these words into its own variable? I think I can do the first and end one but not the Car Import and Car Import one.
I'm working on a software that was developed by someone who left the company. The problem is that the software works for all locations execpt one that is in austria, after debuging I found out that there is a statement in the code that uses boolean true or false, the only way it worked is when I put an if statement with false or true as string, ex: if doc = "true" then buttom line has anyone faced this problem, I searched microsoft website and they said that some vb engines don't convert boolean to string. Please Please if someone has a clue try to help. Thanks.
Hey everyone, I need some help with formatting a string for use with the DoCmd.RunSQL() method. I can't figure out how the hell VB deals with escape characters for the purpse of variables inside strings. I have this line right now.
strSQL = "INSERT INTO OS (OS) VALUES(" + OS.Value + ")"
This is supposed to insert one row into the "OS" Table, in the "OS" field. In my form there is a textbox called "OS" and I'm trying to insert that value into the DB table.
Two things. 1) Yes, I know, I have a lot of things named "OS" 2) Yes, I know I don't need to use a string here, but I'm just presenting this is an abbreviated example, in my full program I do in fact need a string.
I have just inherited a database that has dates stored as strings ex.: 01/01/01. I really do not have time to add a new field and convert the string date to date format (this would cause a lot of rewrite to the application that is using this table). I am trying to use the 'between' to display records that are between specific dates. Also, I am using Cold Fusion as the front end, if that makes any difference. Below is an example I thought might work but did not:
<cfquery name="acty_due_month" datasource="customer"> SELECT acty_end_dt FROM activity Where DateValue(Format([acty_end_dt], "MM/DD/YY"))=10/30/05 </cfquery>
I'm running a 9 parameter query, where values for the criteria are drawn from a form. I'm confused as to how I build an "if, then" string so that if one of the parameters is left blank, the program will skip it and go to the next.
hi, im new to both access and sql and was hoping i could get some help...
i have a string of numbers seperated by commas stored in my database. i need to count how many numbers there are in each string and then display all the results with less than 36 numbers contained.
am i able to do this with an sql statement, or am i likely to need vba??
I have a problem with an SQL query that is used to create a report, the query itself works fine, however I need to get it to do something extra. Basically we have a column that contains 1-3 letters. The letters are A, B and C. The query searches the database and returns result depending on which of the letters we entered. We do this using the like statment -:
SELECT * FROM TableUser WHERE UserType LIKE B
So the above SQL statement returns all entries with the letter B in the column UserType. Also we my need to search for AB, which returns all entries with AB and ABC. The problem is that we sometimes need to search for AC, which should return the values AC and ABC. The problem is that it only returns the values AC and not ABC. I know why it does this as it is searching for a string like 'AC', I am just not sure how to get round the problem. Is there a way of searching the string for the Value AC so that it returns the entries AC and ABC. Thanks in advance for any help. Cheers Andy
I'm trying to create a query that searches the string in a field, for a substring that the user specifies when the query is run. This is the SQL code:
SELECT tblStatement.Date, tblStatement.[Payment Type], tblStatement.Details, tblStatement.[Paid Out], tblStatement.[Paid In] FROM tblStatement WHERE (((tblStatement.Details) Like "**")) ORDER BY tblStatement.Date;
between those two asterixes on the WHERE line, I'd like a string that the user has been prompted for. I've tried this:
WHERE (((tblStatement.Details) Like "*[Enter a String]*"))
But that fails to work, I guess because its in quotations. If I simply had Like [Enter a String], then I get the prompt, but I'll need to enter a string which exactly matches what I am looking for. In other words, I need a query which will search say, "abcdefg" for the user defined input: "abc", which will return that result. I just dont know how to get this to work :s
Can anyone amend this statement because presently I am getting an eror 'The expression you entered has an invlid string 'WHERE Month([PaymentDate])>07 And <11'
When I try to open the recordset with this, it says there is an error in the WHERE clause. I've tried changing all sorts of things but nothing works. I've tried with the WHERE clause commented out and it all works fine then.