473,666 Members | 2,167 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Query To String Converter

I thought I remember a utility that lets you cut a Select statement
from a query and it converts it to be used in VB. Takes the work out
of making sure the syntax is correct.

Anyone know of such a utility?

Jan 1 '07 #1
3 3593
"BerkshireG uy" <be************ *************@y ahoo.comwrote in
news:11******** *************@h 40g2000cwb.goog legroups.com:
I thought I remember a utility that lets you cut a Select statement
from a query and it converts it to be used in VB. Takes the work out
of making sure the syntax is correct.

Anyone know of such a utility?
The SQL created by the Query Wizard? in Access is convoluted, verbose,
inefficient, ugly and bad. (For the young: It sucks!)

One might consider going from the String to to the Stored Definition as a
more productive route. After one has learned to write SQL, many previously
puzzling tasks may seem simple.

In any case the QueryDef's SQL (string property) holds the SQL string.

--
lyle fairfield
Jan 1 '07 #2
Thanks Lyle:

I don't think it's clear. I know how to write SQL, but sometimes I
want to take a query and use the same logic (select statement) in VB
(perhaps in a recordset or whatever). I usually just copy and paste -
but then you need to fix all the syntax - single quote instead of
double, etc. I was wondering if there was a program that formatted a
querys SQL for VBA use.

-=B

Lyle Fairfield wrote:
"BerkshireG uy" <be************ *************@y ahoo.comwrote in
news:11******** *************@h 40g2000cwb.goog legroups.com:
I thought I remember a utility that lets you cut a Select statement
from a query and it converts it to be used in VB. Takes the work out
of making sure the syntax is correct.

Anyone know of such a utility?

The SQL created by the Query Wizard? in Access is convoluted, verbose,
inefficient, ugly and bad. (For the young: It sucks!)

One might consider going from the String to to the Stored Definition as a
more productive route. After one has learned to write SQL, many previously
puzzling tasks may seem simple.

In any case the QueryDef's SQL (string property) holds the SQL string.

--
lyle fairfield
Jan 2 '07 #3
Hi -
You might be thinking of SQL Grabber. It's freeware available at Applecore.
http://www.applecore99.com/dld/dld001.asp

HTH - Bob

BerkshireGuy wrote:
>Thanks Lyle:

I don't think it's clear. I know how to write SQL, but sometimes I
want to take a query and use the same logic (select statement) in VB
(perhaps in a recordset or whatever). I usually just copy and paste -
but then you need to fix all the syntax - single quote instead of
double, etc. I was wondering if there was a program that formatted a
querys SQL for VBA use.

-=B
I thought I remember a utility that lets you cut a Select statement
from a query and it converts it to be used in VB. Takes the work out
[quoted text clipped - 10 lines]
>>
In any case the QueryDef's SQL (string property) holds the SQL string.
--
Message posted via http://www.accessmonster.com

Jan 2 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
3667
by: ma740988 | last post by:
The string object value_f doesn't produce the right output. At issue, - I suspect - is the conversion from string to int with istringstream. An alternate approach? Thanks in advance #include <iostream> #include <sstream> #include <string> using namespace std;
1
5812
by: Mark Rae | last post by:
Hi folks, Apologies - am having a bit of a "senior moment"... Is there a way to convert a string containing escaped characters into a verbatim string literal? I.e. converting something like "This string contains \"double quotes\" and \'single quotes\'"
17
2024
by: Dinsdale | last post by:
I would like to compare a string value to a pre-determined list of other strings. Is there a simple way to do this in one statements like this: if(strMystring.ToUpper() == ("STRING1"| "STRING2"| "STRINGX")) {} This syntax doesn't work (and in fact I'm not quite sure what this statement really is saying) but I'd like to be able to do *something* like this. One suggestion was to add the compare strings to an
26
3796
by: Neville Lang | last post by:
Hi all, I am having a memory blank at the moment. I have been writing in C# for a number of years and now need to do something in VB.NET, so forgive me such a primitive question. In C#, I test whether a string has a value or not by the following syntax: if (thisString.Trim() == "") {
3
1043
by: Jack | last post by:
#include <string> #include <iostream> int main(){ string s= "Application"; return 0; } What am i doing wrong, I get an error message saying 'string undeclared
6
15666
by: DaTurk | last post by:
I'm converting MC++ to C++/CLI and for some reason it's not cool with static const System::String^ How am I supposed to have static constant strings then?
8
71581
by: Pim75 | last post by:
Hello, I'm defining a string array like: Dim strArray() As String = {"1", "2"} Can I add some values to this string array later in the code? It's not clear to me how to do this. I hope someone can help me. Thanks in advance!
6
1981
by: John Kotuby | last post by:
Hi all, I am using a 3rd party program in a VS2005 web project. The tool takes as input a string containing HTML and converts it to RTF. I have been creating a page by dynamically loading UserControls and then sending the page to the browser. Now I want to write the contents of the the page to a string variable, convert that variable to the RTF and send that to the browser and I am stuck on the "simple" part of getting the contents of...
17
2315
by: Sumit | last post by:
hi, I have a url which is a char * char * url = "/url=%2Fhome%2Fsumit%2Fpackages%2Fmyxml.xml"; when i send this URL to http server it was like - "/url=/home/sumit/pacakges/myxml.xml" but when it get by http server it convert '/' to '%2F' i have to
0
8449
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8876
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8784
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8556
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7387
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5666
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4371
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2774
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1777
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.