<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/wordpress-mu-1.2.3-2.2.1" -->
<rss version="2.0" 
	xmlns:content="http://purl.org/rss/1.0/modules/content/">
<channel>
	<title>Comments on: Macro Tip: Don&#8217;t Be Afraid to Make Mistakes</title>
	<link>http://blogs.teamb.com/craigstuntz/2008/03/31/37808</link>
	<description>News of interest to Delphi, .NET, and InterBase developers</description>
	<pubDate>Sun, 07 Sep 2008 06:19:28 +0000</pubDate>
	<generator>http://wordpress.org/?v=wordpress-mu-1.2.3-2.2.1</generator>

	<item>
		<title>By: Craig Stuntz&#8217;s Weblog : SQL-to-Code Macro</title>
		<link>http://blogs.teamb.com/craigstuntz/2008/03/31/37808#comment-3462</link>
		<author>Craig Stuntz&#8217;s Weblog : SQL-to-Code Macro</author>
		<pubDate>Fri, 04 Apr 2008 14:49:05 +0000</pubDate>
		<guid>http://blogs.teamb.com/craigstuntz/2008/03/31/37808#comment-3462</guid>
		<description>[...] I use Delphi macros for converting SQL created in a query analysis tool into Delphi constants, and commenter Jack asked for more details on this. I thought it would make a better post than [...]</description>
		<content:encoded><![CDATA[<p>[&#8230;] I use Delphi macros for converting SQL created in a query analysis tool into Delphi constants, and commenter Jack asked for more details on this. I thought it would make a better post than [&#8230;]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Craig Stuntz</title>
		<link>http://blogs.teamb.com/craigstuntz/2008/03/31/37808#comment-3457</link>
		<author>Craig Stuntz</author>
		<pubDate>Thu, 03 Apr 2008 21:07:47 +0000</pubDate>
		<guid>http://blogs.teamb.com/craigstuntz/2008/03/31/37808#comment-3457</guid>
		<description>Jack,

What I do for Evaluate is to put in something like this:

{$IFOPT D+}MyQuery.SQL.SaveToFile(Filename);{$ENDIF}

... to dump SQL to a file in debugging. 

I'll post the macro separately.</description>
		<content:encoded><![CDATA[<p>Jack,</p>
<p>What I do for Evaluate is to put in something like this:</p>
<p>{$IFOPT D+}MyQuery.SQL.SaveToFile(Filename);{$ENDIF}</p>
<p>&#8230; to dump SQL to a file in debugging. </p>
<p>I&#8217;ll post the macro separately.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jack Rodenhi</title>
		<link>http://blogs.teamb.com/craigstuntz/2008/03/31/37808#comment-3455</link>
		<author>Jack Rodenhi</author>
		<pubDate>Thu, 03 Apr 2008 20:52:08 +0000</pubDate>
		<guid>http://blogs.teamb.com/craigstuntz/2008/03/31/37808#comment-3455</guid>
		<description>Craig,
Thanks for responding.  I am sure I can go through the steps to record a macro.  If I run into something, I will be sure to come back.  The problem, of course, with the rectangular selection is that it will contain unevaluated variables.

I love Delphi but I have always thought it was a shame that no one ever put a multi-line variable viewer in it.  The Evaluate dialog would be a perfect place.  Maybe include a check box for multi-line so you could get something like
SELECT *
FROM EMPLOYEE
that you could paste directly into your query tool 
rather than 
SELECT *#$D#$AFROM EMPLOYEE
which has to be reformatted.

The guys at CodeGear don't miss many opportunities to make life easier on programmers but they missed this one.

-Jack</description>
		<content:encoded><![CDATA[<p>Craig,<br />
Thanks for responding.  I am sure I can go through the steps to record a macro.  If I run into something, I will be sure to come back.  The problem, of course, with the rectangular selection is that it will contain unevaluated variables.</p>
<p>I love Delphi but I have always thought it was a shame that no one ever put a multi-line variable viewer in it.  The Evaluate dialog would be a perfect place.  Maybe include a check box for multi-line so you could get something like<br />
SELECT *<br />
FROM EMPLOYEE<br />
that you could paste directly into your query tool<br />
rather than<br />
SELECT *#$D#$AFROM EMPLOYEE<br />
which has to be reformatted.</p>
<p>The guys at CodeGear don&#8217;t miss many opportunities to make life easier on programmers but they missed this one.</p>
<p>-Jack</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Craig Stuntz</title>
		<link>http://blogs.teamb.com/craigstuntz/2008/03/31/37808#comment-3454</link>
		<author>Craig Stuntz</author>
		<pubDate>Thu, 03 Apr 2008 19:29:34 +0000</pubDate>
		<guid>http://blogs.teamb.com/craigstuntz/2008/03/31/37808#comment-3454</guid>
		<description>Jack,

I don't know any way to share a Delphi macro other than to describe how to make it.  Is that what you would like to see?

For going the other way (from the Delphi editor to a query tool), I generally use rectangular select (hold down the Alt key while dragging the mouse to select).</description>
		<content:encoded><![CDATA[<p>Jack,</p>
<p>I don&#8217;t know any way to share a Delphi macro other than to describe how to make it.  Is that what you would like to see?</p>
<p>For going the other way (from the Delphi editor to a query tool), I generally use rectangular select (hold down the Alt key while dragging the mouse to select).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jack Rodenhi</title>
		<link>http://blogs.teamb.com/craigstuntz/2008/03/31/37808#comment-3451</link>
		<author>Jack Rodenhi</author>
		<pubDate>Mon, 31 Mar 2008 19:15:30 +0000</pubDate>
		<guid>http://blogs.teamb.com/craigstuntz/2008/03/31/37808#comment-3451</guid>
		<description>I will have to check this out.  I do most of my SQL in IBExpert.  I copy it into Ultra-Edit with Alt-V which is a hot key that does the necessary reformatting, then selects all of the text and copies it to the clipboard.  From there I can switch to Delphi and paste it in.  Is it possible to share your macro like I can with Ultra-Edit?

Do you have a tip for going the other way?  The Delphi IDE does not have a memo control for transferring multi-line text.  I have been sending to TraceTool, but I still get the line numbers there which necessitates a trip though Ultra-Edit where I can get rid of them using column editing.</description>
		<content:encoded><![CDATA[<p>I will have to check this out.  I do most of my SQL in IBExpert.  I copy it into Ultra-Edit with Alt-V which is a hot key that does the necessary reformatting, then selects all of the text and copies it to the clipboard.  From there I can switch to Delphi and paste it in.  Is it possible to share your macro like I can with Ultra-Edit?</p>
<p>Do you have a tip for going the other way?  The Delphi IDE does not have a memo control for transferring multi-line text.  I have been sending to TraceTool, but I still get the line numbers there which necessitates a trip though Ultra-Edit where I can get rid of them using column editing.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
