The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 2,364 other followers

Archive for April 14th, 2021

MSSQL – searching in DDL metadata comments

Posted by jpluimers on 2021/04/14

Some interesting queries at [WayBack] www.nlaak.com • Просмотр темы – Полезные скрипты (English translation by Google)

I have put them in the [WayBack] gist below, and expect that they should be solvable without depending on deprecated sys.sysobjects.

Related: [WayBack] sql server – Making sense of sys.objects, sys.system_objects, and sys.sysobjects? – Database Administrators Stack Exchange

–jeroen

Read the rest of this entry »

Posted in Database Development, Development, Software Development, SQL, SQL Server | Leave a Comment »

Plastic SCM: show the current changeset abstract (without files) on the commandline

Posted by jpluimers on 2021/04/14

I could not find a syntax for “current changeset”, but since cm log accepts the output of cm status as changeset identifier:

for /F "tokens=*" %l in ('call cm status --nochanges') do (call cm log %l --itemformat )

Or in batch file form:

for /F "tokens=*" %%l in ('call cm status --nochanges') do (call cm log %%l --itemformat )

Two important parts of the trick that ensure each command only outputs what is needed:

  1. The empty --itemformat specification for cm log indicates that no details about files should be logged.Without it, cm log will list both the changeset information and information about each item in the changeset.
  2. The other trick is --nochanges for cm status: it only shows the status line, and no other changes.Without it, cm status will emit one line per changed file.

–jeroen

Read the rest of this entry »

Posted in Development, PlasticSCM, Software Development, Source Code Management | Leave a Comment »

“F2063 Could not compile used unit” can also mean you have a DCU file of that unit for the wrong compiler version

Posted by jpluimers on 2021/04/14

It took me a file to figure out another cause for “F2063 Could not compile used unit“, this was for a 3rd party library that had parts of the units as source files, but other parts as DCU files.

The offending unit only had DCU files, and those were in the path.

It finally occurred to me that I had a project having a DCU for the wrong Delphi version in the path.

That version check is easy to do: the 4th byte of a unit contains the CompilerVersion value with which the DCU file was compiled, and should be used with:

The first entry is for CompilerVersion value 31 (for hexadecimal value $1F) which corresponds with Delphi 10.2 Tokyo.

The last last is for CompilerVersion value 32 (for hexadecimal value $20) which corresponds with Delphi 10.3 Rio.

All versions are in Delphi version info table: C# Builder, Delphi 8 through 10.3 Rio and Appbuilder.

Related:

On the DCU and TPU file formats:

–jeroen

Posted in Delphi, Development, Software Development | Leave a Comment »

 
%d bloggers like this: