content fetching operator like the SQL "where zipCode LIKE '89%'"

Author Message

Robin de Silva Jayasinghe

Monday 25 October 2004 12:06:46 am

hello,

is there an template-operator which works like the LIKE operator in SQL?

SELECT * FROM cities WHERE zipCode LIKE '89%'"

my intention is to fetch only the content-objects which attribute "zipCode" has a value beginning with "89".

regards,
robin

visit http://www.jayasinghe.de

Björn Dieding@xrow.de

Monday 25 October 2004 4:40:03 pm

Paul Borgermans and his guys from belgium have a modified ezcontentobject.php class that can match contentobject attributes like "like"

http://pubsvn.ez.no

Looking for a new job? http://www.xrow.com/xrow-GmbH/Jobs
Looking for hosting? http://hostingezpublish.com
-----------------------------------------------------------------------------
GMT +01:00 Hannover, Germany
Web: http://www.xrow.com/

Robin de Silva Jayasinghe

Monday 25 October 2004 8:28:16 pm

thanks a lot! i'll have a look on that..

und viele gruesse nach hannover ! ;)

visit http://www.jayasinghe.de

Robin de Silva Jayasinghe

Tuesday 26 October 2004 5:26:32 am

hmm.. where exactly can i find the file on that site (http://pubsvn.ez.no)? in the "community" or the "ezPublish" - area? is there something like a search functionality ?

regards,
robin

visit http://www.jayasinghe.de

Tobias Persson

Tuesday 26 October 2004 5:36:05 am

Not sure, but this might be the one??
http://www.ez.no/community/contributions/hacks/more_attribute_filter_operators_and_fetch_by_owner_id

Paul Borgermans

Tuesday 26 October 2004 5:38:05 am

Robin,

You can download a version for the latest stable here:

http://ez.no/community/contributions/hacks/more_attribute_filter_operators_and_fetch_by_owner_id

I will post this also as an "extended attribute filter" which makes this independent of ezp upgrades. I guess most of the functionality will land in the trunk (post 3.5 because of the feature freeze)

hth

-paul

eZ Publish, eZ Find, Solr expert consulting and training
http://twitter.com/paulborgermans

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 19 2025 03:39:48
Script start
Timing: Jan 19 2025 03:39:48
Module start 'layout'
Timing: Jan 19 2025 03:39:48
Module start 'content'
Timing: Jan 19 2025 03:39:49
Module end 'content'
Timing: Jan 19 2025 03:39:49
Script end

Main resources:

Total runtime0.9169 sec
Peak memory usage4,096.0000 KB
Database Queries70

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0053 589.4141152.6563
Module start 'layout' 0.00530.0034 742.070339.5078
Module start 'content' 0.00870.9065 781.5781662.7500
Module end 'content' 0.91530.0015 1,444.328116.0938
Script end 0.9168  1,460.4219 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00310.3380160.0002
Check MTime0.00130.1403160.0001
Mysql Total
Database connection0.00080.084210.0008
Mysqli_queries0.851292.8378700.0122
Looping result0.00070.0761680.0000
Template Total0.886496.720.4432
Template load0.00200.220420.0010
Template processing0.884496.457120.4422
Template load and register function0.00010.014610.0001
states
state_id_array0.00110.121910.0011
state_identifier_array0.00140.158120.0007
Override
Cache load0.00190.2020350.0001
Sytem overhead
Fetch class attribute can translate value0.00070.081840.0002
Fetch class attribute name0.00110.1196100.0001
XML
Image XML parsing0.00530.575640.0013
class_abstraction
Instantiating content class attribute0.00000.0020120.0000
General
dbfile0.00440.4846350.0001
String conversion0.00000.000940.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
6content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
6content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
9content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
3content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 27
 Number of unique templates used: 7

Time used to render debug report: 0.0001 secs