Migrations - Adding an index changes table name to lower-case !!

Mark Gowdy <[email protected]> Thu, 25 Jun 2015 15:47:02 +0100
Newsgroups gmane.comp.web.webobjects.wonder-disc
Message-ID <[email protected]>
--===============6547000430835759226==
Content-Type: multipart/alternative;
	boundary="Apple-Mail=_EB1D1B69-D2B4-4BA1-AD7A-C7A629017A54"


--Apple-Mail=_EB1D1B69-D2B4-4BA1-AD7A-C7A629017A54
Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain;
	charset=utf-8

Hi,=20

Before I start digging into the generated SQL via MySQL debug mode, has =
anyone else experienced this?

I have a table called =E2=80=9CTag=E2=80=9D

In my migrations code, I am adding an index to this table:
	ERXMigrationTable tagTable =3D =
database.existingTableNamed("Tag");
	tagTable.addIndex("Parent_FK_IDX", "parentFK");

The moment that runs, the table name has been lower-cased to =E2=80=98tag=E2=
=80=99 (as viewed in SequalPro)

Experimenting, I found that using =E2=80=98addUniqueIndex=E2=80=99 does =
_not_ cause the same issue.

I am running:
Wonder version: 6.1.4-SNAPSHOT
mysql-connector-java-5.1.35-bin.jar



While I am here:
1) I recently upgraded to the latest (stable) Wonder version, is 6.1.4 =
the right one?   Or should it be 7.x ?
2) Are mixed case table names a bad idea?  I used to make all tables =
lowercase, but decided to changed this for new projects. =20

Thanks,=20

Mark=

--Apple-Mail=_EB1D1B69-D2B4-4BA1-AD7A-C7A629017A54
Content-Transfer-Encoding: quoted-printable
Content-Type: text/html;
	charset=utf-8

<html><head><meta http-equiv=3D"Content-Type" content=3D"text/html =
charset=3Dutf-8"></head><body style=3D"word-wrap: break-word; =
-webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" =
class=3D"">Hi,&nbsp;<div class=3D""><br class=3D""></div><div =
class=3D""><div style=3D"margin: 0px;" class=3D"">Before I start digging =
into the generated SQL via MySQL debug mode, has anyone else experienced =
this?</div></div><div class=3D""><br class=3D""></div><div class=3D"">I =
have a table called =E2=80=9CTag=E2=80=9D</div><div class=3D""><br =
class=3D""></div><div class=3D"">In my migrations code, I am adding an =
index to this table:</div><div class=3D""><div style=3D"margin: 0px; =
font-size: 11px; font-family: Monaco;" class=3D""><span =
class=3D"Apple-tab-span" style=3D"white-space:pre">	=
</span>ERXMigrationTable <span style=3D"color: #7e504f" =
class=3D"">tagTable</span> =3D <span style=3D"color: #7e504f" =
class=3D"">database</span>.existingTableNamed(<span style=3D"color: =
#3933ff" class=3D"">"Tag"</span>);</div><div style=3D"margin: 0px; =
font-size: 11px; font-family: Monaco; color: rgb(57, 51, 255);" =
class=3D""><span style=3D"color: #000000" class=3D""><span =
class=3D"Apple-tab-span" style=3D"white-space:pre">	=
</span></span><span style=3D"color: #7e504f" =
class=3D"">tagTable</span><span style=3D"color: #000000" =
class=3D"">.addIndex(</span>"Parent_FK_IDX"<span style=3D"color: =
#000000" class=3D"">, </span>"parentFK"<span style=3D"color: #000000" =
class=3D"">);</span></div></div><div class=3D""><br class=3D""></div><div =
class=3D"">The moment that runs, the table name has been lower-cased to =
=E2=80=98tag=E2=80=99 (as viewed in SequalPro)</div><div class=3D""><br =
class=3D""></div><div class=3D"">Experimenting, I found that using =
=E2=80=98<span style=3D"font-family: Monaco; font-size: 11px;" =
class=3D"">addUniqueIndex</span>=E2=80=99 does _not_ cause the same =
issue.</div><div class=3D""><br class=3D""></div><div class=3D"">I am =
running:</div><div class=3D""><div style=3D"margin: 0px; font-size: =
11px; font-family: Monaco;" class=3D"">Wonder version: =
6.1.4-SNAPSHOT</div></div><div style=3D"margin: 0px;" class=3D""><font =
face=3D"Monaco" class=3D""><span style=3D"font-size: 11px;" =
class=3D"">mysql-connector-java-5.1.35-bin.jar</span></font></div><div =
style=3D"margin: 0px;" class=3D""><font face=3D"Monaco" class=3D""><span =
style=3D"font-size: 11px;" class=3D""><br =
class=3D""></span></font></div><div style=3D"margin: 0px;" =
class=3D""><font face=3D"Monaco" class=3D""><span style=3D"font-size: =
11px;" class=3D""><br class=3D""></span></font></div><div style=3D"margin:=
 0px;" class=3D""><br class=3D""></div><div style=3D"margin: 0px;" =
class=3D"">While I am here:</div><div style=3D"margin: 0px;" class=3D"">1)=
 I recently upgraded to the latest (stable) Wonder version, is 6.1.4 the =
right one? &nbsp; Or should it be 7.x ?</div><div style=3D"margin: 0px;" =
class=3D"">2) Are mixed case table names a bad idea? &nbsp;I used to =
make all tables lowercase, but decided to changed this for new projects. =
&nbsp;</div><div style=3D"margin: 0px;" class=3D""><br =
class=3D""></div><div style=3D"margin: 0px;" =
class=3D"">Thanks,&nbsp;</div><div style=3D"margin: 0px;" class=3D""><br =
class=3D""></div><div style=3D"margin: 0px;" =
class=3D"">Mark</div></body></html>=

--Apple-Mail=_EB1D1B69-D2B4-4BA1-AD7A-C7A629017A54--


--===============6547000430835759226==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

------------------------------------------------------------------------------
Monitor 25 network devices or servers for free with OpManager!
OpManager is web-based network management software that monitors 
network devices and physical & virtual servers, alerts via email & sms 
for fault. Monitor 25 devices for free with no restriction. Download now
http://ad.doubleclick.net/ddm/clk/292181274;119417398;o
--===============6547000430835759226==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Wonder-disc mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wonder-disc

--===============6547000430835759226==--