I've only just started out with CF9's ORM features, and have run into a problem.
I've got a single table set up - member - which has 2 records in it.
If I try:
<cfscript>
members = EntityLoad("member");
writedump(members);
</cfscript>
...I should get an array of member objects; but I get the error:
unexpected token: member near line 1, column 6 [from member]
The error occurred in \\vmware-host\Shared
Folders\Web\sites\testbed\webroot\orm\index.cfm: line 2
1 : <cfscript>
2 : members = EntityLoad("member");
3 : writedump(members);
4 : </cfscript>
If I try:
<cfscript>
members = EntityLoad("member", {});
writedump(members);
</cfscript>
...I get the expected array of 2 member objects - but it takes 5-10 seconds to return it.
But if I request a unique object:
<cfscript>
members = EntityLoad("member", 1, true);
writedump(members);
</cfscript>
...I get the result returned instantaneously.
Any ideas as to what the problem(s) is/are?
member.cfc:
component output="false" persistent="true"
{
// identifier
property name="memberid" fieldtype="id";
// properties
property name="firstname";
property name="lastname";
property name="address1";
property name="address2";
property name="city";
property name="postcode";
property name="country";
property name="email";
property name="telephone";
property name="uuid";
property name="password";
}